package com.example.a20112.ui_demo.retrofitservice;

import com.example.a20112.ui_demo.beans.CollectBean;
import com.example.a20112.ui_demo.beans.FoodListBean;
import com.example.a20112.ui_demo.beans.LoginBean;
import com.example.a20112.ui_demo.beans.RegisterBean;
import com.example.a20112.ui_demo.beans.ShopBean;

import java.util.List;

import retrofit2.Call;
import retrofit2.http.GET;
import retrofit2.http.Query;

public interface UserService {
    @GET("userRegister.do")
    Call<RegisterBean> register(
            @Query("username")String username,
            @Query("userpass")String password1,
            @Query("address")String address,
            @Query("mobilenum")String phonenumber,
            @Query("comment")String comment

    );
    @GET("userLogin.do")
    Call<LoginBean> login(
            @Query("username")String usernameview,
            @Query("userpass")String passwordview
    );


    /*店铺列表*/
    @GET("getAllShops.do")
    Call<List<ShopBean>>getAllShops();
    //(
//            @Query("shop_id")String shop_id,
//            @Query("shopname")String shopname,
//            @Query("address")String address,
//            @Query("phonenum")String phonenum,
//            @Query("intro")String intro,
//            @Query("pic")String pic,
//            @Query("comment")String comment,
//            @Query("level")String level
//
//
//    );
    /*菜品列表*/
    @GET("getFoodByShop.do")
    Call<List<FoodListBean>> getFoodByShop(@Query("shop_id") int shop_id);

    /*收藏*/
    @GET("isCollected.do")
    Call<List<CollectBean>>isCollected(
            @Query("user_id")int user_id,
            @Query("shop_food_id")int shop_food_id,
            @Query("flag")int flag
    );
}
